<div class="draw-content">
    <div class="container">
        <nz-tabset [nzSelectedIndex]='nzSelectedIndex'>
            <nz-tab *ngFor="let tab of tabArr" [nzDisabled]="tab.tabStatus" (nzClick)="Select(['click', tab])"
                    nzTitle="{{tab.title}}">
                <!--合并-->
                <div *ngIf="showMergeIcon">
                    <div class="drae-save">
                        <div class="check">
                            <button class="pointe" nz-button nzType="primary" nzShape="circle" (click)="mergeFinish(drawType)">
                                <i nz-icon nzType="check" nzTheme="outline"></i>
                            </button>
                        </div>
                        <div class="close">
                            <button class="pointe" nz-button nzType="primary" nzShape="circle" (click)="mergeClose(drawType)">
                                <i nz-icon nzType="close" nzTheme="outline"></i>
                            </button>
                        </div>
                    </div>
                </div>
                <!--拆分-->
                <div style="padding:0 0 10px 10px; color: red" *ngIf="drawType ===5 && title">{{title}}</div>
                <div *ngIf="showSplitSelectType">
                    <nz-tabset  [nzSelectedIndex]='nzSelectedIndex'>
                        <nz-tab *ngFor="let tab of splitList" (nzClick)="splitFun(['click', tab])"
                                nzTitle="{{tab.title}}">
                        </nz-tab>
                    </nz-tabset>
                </div>
                <!--编辑-->
                <div *ngIf="addFeatureModel">
                    <kylin-add-feature-attr
                        (finish)="isOK($event)"
                        (clone)="isClone($event)"
                        (getFeatureAttr)="getFeatureAttr($event)"
                        [drawType]="drawType"
                        [addFeatureModel]='addFeatureModel'
                        [definLayer]=definLayerJson
                        [showIcon]='showIcon'
                        [currentSelectFeature]='currentSelectFeature'
                        (emitColor) = 'emitColor($event)'
                    ></kylin-add-feature-attr>
                </div>
                <!--列表-->
                <div *ngIf="!addFeatureModel">
                    <kylin-layers-list
                        [LayersGeoJson]=allLayersListData
                        (newLayersFun)='newLayersFun($event)'
                        (deteleLayFun)='deleteLayers($event)'
                        (issueLayerUpDataFun)='issueLayerUpDataFun()'
                        (selectFeatureFun)='selectFeatureFun($event)'
                        (visibility)="visibility($event)"
                        [LayersListDataLayers]='mapAllLayersListData'
                    ></kylin-layers-list>
                </div>
            </nz-tab>
        </nz-tabset>
    </div>
</div>


<!--新增图层-->
<nz-modal [(nzVisible)]="layeryShow" [nzTitle]="'新建图层'" [nzFooter]="modalFooter" (nzOnCancel)="handleCancel()">
    <form class="user-form" [formGroup]="layersForm" *ngIf="layersForm">
        <table class="info-box" cellspacing="0">
            <!--图层类型-->
            <tr style="margin-bottom: 20px">
                <td class="label-td">图层类型</td>
                <td class="input-td">
                    <nz-select formControlName="layersType">
                        <nz-option [nzValue]="1" [nzLabel]="'点图层'"></nz-option>
                        <nz-option [nzValue]="2" [nzLabel]="'线图层'"></nz-option>
                        <nz-option [nzValue]="3" [nzLabel]="'面图层'"></nz-option>
                    </nz-select>
                </td>
            </tr>
            <!--图层名称-->
            <tr>
                <td class="label-td">图层名称</td>
                <td class="input-td">
                    <input nz-input formControlName="layersName" placeholder="请输入图层名称">
                </td>
            </tr>
        </table>
    </form>
    <ng-template #modalFooter>
        <button nz-button nzType="default" (click)="handleCancel()">取消</button>
        <button nz-button nzType="primary" (click)="submitLayers()" [nzLoading]="loading">确认</button>
    </ng-template>
</nz-modal>


